Optimal. Leaf size=63 \[ -\frac {b p}{a \sqrt {x}}+\frac {b^2 p \log \left (a+b \sqrt {x}\right )}{a^2}-\frac {\log \left (c \left (a+b \sqrt {x}\right )^p\right )}{x}-\frac {b^2 p \log (x)}{2 a^2} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.03, antiderivative size = 63, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 3, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {2504, 2442, 46}
\begin {gather*} \frac {b^2 p \log \left (a+b \sqrt {x}\right )}{a^2}-\frac {b^2 p \log (x)}{2 a^2}-\frac {\log \left (c \left (a+b \sqrt {x}\right )^p\right )}{x}-\frac {b p}{a \sqrt {x}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 46
Rule 2442
Rule 2504
Rubi steps
\begin {align*} \int \frac {\log \left (c \left (a+b \sqrt {x}\right )^p\right )}{x^2} \, dx &=2 \text {Subst}\left (\int \frac {\log \left (c (a+b x)^p\right )}{x^3} \, dx,x,\sqrt {x}\right )\\ &=-\frac {\log \left (c \left (a+b \sqrt {x}\right )^p\right )}{x}+(b p) \text {Subst}\left (\int \frac {1}{x^2 (a+b x)} \, dx,x,\sqrt {x}\right )\\ &=-\frac {\log \left (c \left (a+b \sqrt {x}\right )^p\right )}{x}+(b p) \text {Subst}\left (\int \left (\frac {1}{a x^2}-\frac {b}{a^2 x}+\frac {b^2}{a^2 (a+b x)}\right ) \, dx,x,\sqrt {x}\right )\\ &=-\frac {b p}{a \sqrt {x}}+\frac {b^2 p \log \left (a+b \sqrt {x}\right )}{a^2}-\frac {\log \left (c \left (a+b \sqrt {x}\right )^p\right )}{x}-\frac {b^2 p \log (x)}{2 a^2}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.03, size = 55, normalized size = 0.87 \begin {gather*} -\frac {\log \left (c \left (a+b \sqrt {x}\right )^p\right )}{x}-\frac {b p \left (\frac {2 a}{\sqrt {x}}-2 b \log \left (a+b \sqrt {x}\right )+b \log (x)\right )}{2 a^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.03, size = 0, normalized size = 0.00 \[\int \frac {\ln \left (c \left (a +b \sqrt {x}\right )^{p}\right )}{x^{2}}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.28, size = 53, normalized size = 0.84 \begin {gather*} \frac {1}{2} \, b p {\left (\frac {2 \, b \log \left (b \sqrt {x} + a\right )}{a^{2}} - \frac {b \log \left (x\right )}{a^{2}} - \frac {2}{a \sqrt {x}}\right )} - \frac {\log \left ({\left (b \sqrt {x} + a\right )}^{p} c\right )}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.42, size = 55, normalized size = 0.87 \begin {gather*} -\frac {b^{2} p x \log \left (\sqrt {x}\right ) + a b p \sqrt {x} + a^{2} \log \left (c\right ) - {\left (b^{2} p x - a^{2} p\right )} \log \left (b \sqrt {x} + a\right )}{a^{2} x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 326 vs.
\(2 (56) = 112\).
time = 10.81, size = 326, normalized size = 5.17 \begin {gather*} \begin {cases} - \frac {2 a^{3} \sqrt {x} \log {\left (c \left (a + b \sqrt {x}\right )^{p} \right )}}{2 a^{3} x^{\frac {3}{2}} + 2 a^{2} b x^{2}} - \frac {2 a^{2} b p x}{2 a^{3} x^{\frac {3}{2}} + 2 a^{2} b x^{2}} - \frac {2 a^{2} b x \log {\left (c \left (a + b \sqrt {x}\right )^{p} \right )}}{2 a^{3} x^{\frac {3}{2}} + 2 a^{2} b x^{2}} - \frac {a b^{2} p x^{\frac {3}{2}} \log {\left (x \right )}}{2 a^{3} x^{\frac {3}{2}} + 2 a^{2} b x^{2}} - \frac {2 a b^{2} p x^{\frac {3}{2}}}{2 a^{3} x^{\frac {3}{2}} + 2 a^{2} b x^{2}} + \frac {2 a b^{2} x^{\frac {3}{2}} \log {\left (c \left (a + b \sqrt {x}\right )^{p} \right )}}{2 a^{3} x^{\frac {3}{2}} + 2 a^{2} b x^{2}} - \frac {b^{3} p x^{2} \log {\left (x \right )}}{2 a^{3} x^{\frac {3}{2}} + 2 a^{2} b x^{2}} + \frac {2 b^{3} x^{2} \log {\left (c \left (a + b \sqrt {x}\right )^{p} \right )}}{2 a^{3} x^{\frac {3}{2}} + 2 a^{2} b x^{2}} & \text {for}\: a \neq 0 \\- \frac {p}{2 x} - \frac {\log {\left (c \left (b \sqrt {x}\right )^{p} \right )}}{x} & \text {otherwise} \end {cases} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 132 vs.
\(2 (55) = 110\).
time = 5.65, size = 132, normalized size = 2.10 \begin {gather*} -\frac {\frac {b^{3} p \log \left (b \sqrt {x} + a\right )}{{\left (b \sqrt {x} + a\right )}^{2} - 2 \, {\left (b \sqrt {x} + a\right )} a + a^{2}} - \frac {b^{3} p \log \left (b \sqrt {x} + a\right )}{a^{2}} + \frac {b^{3} p \log \left (b \sqrt {x}\right )}{a^{2}} + \frac {{\left (b \sqrt {x} + a\right )} b^{3} p - a b^{3} p + a b^{3} \log \left (c\right )}{{\left (b \sqrt {x} + a\right )}^{2} a - 2 \, {\left (b \sqrt {x} + a\right )} a^{2} + a^{3}}}{b} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.66, size = 49, normalized size = 0.78 \begin {gather*} \frac {2\,b^2\,p\,\mathrm {atanh}\left (\frac {2\,b\,\sqrt {x}}{a}+1\right )}{a^2}-\frac {\ln \left (c\,{\left (a+b\,\sqrt {x}\right )}^p\right )}{x}-\frac {b\,p}{a\,\sqrt {x}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________